<?php if (!defined('THINK_PATH')) exit();?><!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
        <title>Insert title here</title>
    <script type="text/javascript" src="__ROOT__/Public/js/jquery.min.js"></script>
    <script type="text/javascript" src="__ROOT__/Public/js/jquery.form.js"></script>
    <link rel="stylesheet" type="text/css" href="/Public/css/admin.css" />
    <script type="text/javascript">
        var UEDITOR_HOME_URL = "__PUBLIC__/ueditor/";
    </script>
    <script type="text/javascript" src="__ROOT__/Public/ueditor/editor_config.js"></script>
    <script type="text/javascript" src="__ROOT__/Public/js/jquery.min.js" ></script>
    <script type="text/javascript" src="__ROOT__/Public/ueditor/editor_all.js"></script>
    <style type="text/css">
        td{background: #fff;}
    </style>
</head>
<body>
    <div id="bds">
        <span style="width:1200px; height: 60px; display: block; line-height: 60px; text-align:center; font-size: 40px; font-weight: bold; font-family:微软雅黑; letter-spacing: 5px;background-color: #e1e1e1;">
            板块管理
        </span>
        <form action ="__URL__/add" method="post">
            <table class="tables" border="0" cellpadding="0" cellspacing="1" style=" width: 1200px;border-top: 0px solid #e1e1e1; background: #000;">
                <tr>
                    <td height="30px" width="200px" >上级菜单</td>
                    <td width="1000px" ><select style="float: left;" id="pid" name="pid" onchange="sel()">
                            <option value="0">顶级菜单</option>
                            <?php if(is_array($menu1)): foreach($menu1 as $key=>$menu1): ?><option value="<?php echo ($menu1["Id"]); ?>" onclick="sel()"><?php echo ($menu1["menu"]); ?></option><?php endforeach; endif; ?>
                        </select></td>
                </tr>
                <tr>
                    <td height="30px" >菜单名称</td>
                    <td><input style="float: left;"  type="text" name="menu_name" /></td>
                </tr>
                <tr>
                    <td height="30px" >帮助内容</td>
                    <td>
                        <div name="content" id="newscontent" style="float: left;display: none;"></div>
                        <script type="text/javascript">
                            var editor = new baidu.editor.ui.Editor();
                            editor.render('newscontent');
                        </script>
                    </td>
                </tr>
                <tr>
                    <td height="30px" >排序id</td>
                    <td><input style="float: left;"  type="text" size="2" name="fost" value="1"/><span style="float: left;line-height: 28px;">[必填项]数值越小，排列越前</span></td>
                </tr>
                <tr>
                    <td height="30px" >状态</td>
                    <td><select name="str" style="float: left;">
                            <option value="1" selected="selected">显示</option>
                            <option value="0">隐藏</option>
                        </select></td>
                </tr>
                <tr>
                    <td height="30px" ></td>
                    <td> <input style="float: left;" type="submit" />  </td>
                </tr>
            </table>
        </form>
    </div>
    <script type="text/javascript">
        function sel(){
            var pid = $("#pid").val();
            if(pid == 0){
                $("#newscontent").hide();
            }else{
                $("#newscontent").show();
            }
        }
        sel();
    </script>
</body>
</html>